package com.yc.Di.test.bean3;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;



@Component
public class Person {
    @Value("#{ T(java.lang.Math).random()*1000 }")
    int id;

    @Value("#{ new String('hello world').toUpperCase() }")
    String str;


    @Override
    public String toString() {

        return "Person{" +
                "id=" + id +
                ", str='" + str + '\'' +
                '}';
    }
}
